<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>导航栏案例</title>
    <style>
        * {
            /* 清除元素默认样式 */
            margin: 0;
            padding: 0;
        }

/* 清除列表前的点 */
        li {
            list-style: none;
        }

        .banner {
            width: 760px;
            height: 150px;
            margin: auto;
            background-color: pink;
        }

        .nav {
            width: 760px;
            height: 32px;
            background: url(./images/nav_bg.jpg) repeat-x;
            margin: auto;
        }

        .nav ul li{
            float: left;
        }

        a{
            display: block;
            width: 80px;
            height: 32px;
            background: url(./images/button1.jpg);
            text-decoration: none;
            text-align: center;
            line-height: 32px;
            font-size: 12px;
            color: black;
        }

        a:hover{
            background: url(./images/button2.jpg);
        }
    </style>
</head>

<body>
    <!-- banner广告条 -->
    <div class="banner">
        <img src="./images/banner.jpg">
    </div>
    <!-- 导航栏 -->
    <div class="nav">
        <ul>
            <li>
                <a href="#">网站首页</a>
            </li>
            <li>
                <a href="#">网站首页</a>
            </li>
            <li>
                <a href="#">网站首页</a>
            </li>
            <li>
                <a href="#">网站首页</a>
            </li>
            <li>
                <a href="#">网站首页</a>
            </li>
            <li>
                <a href="#">网站首页</a>
            </li>
        </ul>
    </div>
</body>

</html>